<?php if(!class_exists('raintpl')){exit;}?><?php $tpl = new RainTPL;$tpl_dir_temp = self::$tpl_dir;$tpl->assign( $this->var );$tpl->draw( dirname("header") . ( substr("header",-1,1) != "/" ? "/" : "" ) . basename("header") );?>

<?php echo carouFredSel(); ?>

<div class ="wrapper">

	<div class = "main" id = "channel">
		<h1 class = "fr"><?php echo $e['channel'];?></h1>

		<div class = "content">
			<iframe width="680" height="382" src="http://www.youtube.com/embed/<?php echo $channel['yid'];?>" frameborder="0" allowfullscreen></iframe>

			<h2><?php echo $channel['channel'];?></h2>
			<span><?php echo $channel['detail'];?></span>
		</div>

		<div id = "wrapper-relate" class = "clear">
			<h3><?php echo $e['other-channel'];?></h3>
			<img src="http://localhost/waterfantasy/html/images/btn-prev.png" id = "btn-prev" class = "btn-prev">
			<img src="http://localhost/waterfantasy/html/images/btn-next.png" id = "btn-next" class = "btn-next">
			<ul id = "relate">
				<?php $counter1=-1; if( isset($all_channel) && is_array($all_channel) && sizeof($all_channel) ) foreach( $all_channel as $key1 => $value1 ){ $counter1++; ?>
				<li>
					<a href = "channel.html?id=<?php echo $value1["id"];?>">
						<img src = "<?php echo $value1["image"];?>" class = "thumb" width = "150" height = "90">
						<span class = "desc"><?php echo $value1["channel"];?></span>
					</a>
				</li>
				<?php } ?>
			</ul>
		</div>
	</div>

	<div class = "sidebar">
		<ul>
			<li><?php echo $e['gallery'];?> & <?php echo $e['channel'];?></li>
			<li><a href = "gallery.html"><?php echo $e['gallery'];?></a></li>
			<li><a href = "channel.html"><?php echo $e['channel'];?></a></li>
		</ul>
	</div>
</div>

<style>
	.caroufredsel_wrapper {height:153px;}
</style>

<script>

$(document).ready(function(){
    $("#relate").carouFredSel({
		auto : false,
		circular : false,
		infinite : false,
		excludedElements: "button, input, select, textarea, .noSwipe",
		width : 600,
		prev : {
			button : "#btn-prev",
			key : "left"
		},
		next : {
			button : "#btn-next",
			key : "right"
		},
		swipe : {
			onTouch : true,
		},
	});
});
</script>

<?php $tpl = new RainTPL;$tpl_dir_temp = self::$tpl_dir;$tpl->assign( $this->var );$tpl->draw( dirname("footer") . ( substr("footer",-1,1) != "/" ? "/" : "" ) . basename("footer") );?>